package org.dllwh.mysql.service.impl;


import jakarta.annotation.Resource;
import org.dllwh.mysql.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.stereotype.Service;

/**
 * 把今天最好的表现当作明天最新的起点．．～
 * <p>
 * Today the best performance as tomorrow the newest starter!
 *
 * @ClassName UserServiceImpl
 * @Description 用户服务实现类
 * @Date 2025-09-17 18:06
 * @版本 V 1.0.1
 * @since JDK 17
 */
@Service
public class UserServiceImpl implements UserService {
    @Resource
    private JdbcTemplate jdbcTemplate;

    @Override
    public Integer getUserCount() {
        return jdbcTemplate.queryForObject("select count(1) from sys_user", Integer.class);
    }
}
